package com.mdb.open.epay.service.epay;

import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.mdb.bc.database.mybatisplus.SuperService;
import com.mdb.open.epay.common.MdbDataSource;
import com.mdb.open.epay.domain.po.epay.QpUserOpen;
import com.mdb.open.epay.mapper.epay.QpUserOpenMapper;
import org.springframework.stereotype.Service;

/**
 * 类描述：
 *  用户快捷开通表 服务类
 *
 * @author liuyi
 * @date 2019-11-14
 */
@Service
@DS(MdbDataSource.EPAY)
public class QpUserOpenService extends SuperService<QpUserOpenMapper, QpUserOpen> {

    public QpUserOpen get(String customerCode, String prodCode, String bankAccNo) {
        return this.baseMapper.selectOne(new LambdaQueryWrapper<QpUserOpen>()
                .eq(QpUserOpen::getCustomerCode, customerCode)
                .eq(QpUserOpen::getProdCode, prodCode)
                .eq(QpUserOpen::getBankAccNo, bankAccNo));
    }
}
